3.558 \(\int \frac{x^{-1+\frac{n}{2}}}{a+b x^n+c x^{2 n}} \, dx\)

Optimal. Leaf size=169 \[ \frac{2 \sqrt{2} \sqrt{c} \tan ^{-1}\left (\frac{\sqrt{2} \sqrt{c} x^{n/2}}{\sqrt{b-\sqrt{b^2-4 a c}}}\right )}{n \sqrt{b^2-4 a c} \sqrt{b-\sqrt{b^2-4 a c}}}-\frac{2 \sqrt{2} \sqrt{c} \tan ^{-1}\left (\frac{\sqrt{2} \sqrt{c} x^{n/2}}{\sqrt{\sqrt{b^2-4 a c}+b}}\right )}{n \sqrt{b^2-4 a c} \sqrt{\sqrt{b^2-4 a c}+b}} \]

[Out]

(2*Sqrt[2]*Sqrt[c]*ArcTan[(Sqrt[2]*Sqrt[c]*x^(n/2))/Sqrt[b - Sqrt[b^2 - 4*a*c]]]
)/(Sqrt[b^2 - 4*a*c]*Sqrt[b - Sqrt[b^2 - 4*a*c]]*n) - (2*Sqrt[2]*Sqrt[c]*ArcTan[
(Sqrt[2]*Sqrt[c]*x^(n/2))/Sqrt[b + Sqrt[b^2 - 4*a*c]]])/(Sqrt[b^2 - 4*a*c]*Sqrt[
b + Sqrt[b^2 - 4*a*c]]*n)

_______________________________________________________________________________________

Rubi [A]  time = 0.367823, antiderivative size = 169, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 3, integrand size = 26, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.115 \[ \frac{2 \sqrt{2} \sqrt{c} \tan ^{-1}\left (\frac{\sqrt{2} \sqrt{c} x^{n/2}}{\sqrt{b-\sqrt{b^2-4 a c}}}\right )}{n \sqrt{b^2-4 a c} \sqrt{b-\sqrt{b^2-4 a c}}}-\frac{2 \sqrt{2} \sqrt{c} \tan ^{-1}\left (\frac{\sqrt{2} \sqrt{c} x^{n/2}}{\sqrt{\sqrt{b^2-4 a c}+b}}\right )}{n \sqrt{b^2-4 a c} \sqrt{\sqrt{b^2-4 a c}+b}} \]

Antiderivative was successfully verified.

[In]  Int[x^(-1 + n/2)/(a + b*x^n + c*x^(2*n)),x]

[Out]

(2*Sqrt[2]*Sqrt[c]*ArcTan[(Sqrt[2]*Sqrt[c]*x^(n/2))/Sqrt[b - Sqrt[b^2 - 4*a*c]]]
)/(Sqrt[b^2 - 4*a*c]*Sqrt[b - Sqrt[b^2 - 4*a*c]]*n) - (2*Sqrt[2]*Sqrt[c]*ArcTan[
(Sqrt[2]*Sqrt[c]*x^(n/2))/Sqrt[b + Sqrt[b^2 - 4*a*c]]])/(Sqrt[b^2 - 4*a*c]*Sqrt[
b + Sqrt[b^2 - 4*a*c]]*n)

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 34.2183, size = 151, normalized size = 0.89 \[ - \frac{2 \sqrt{2} \sqrt{c} \operatorname{atan}{\left (\frac{\sqrt{2} \sqrt{c} x^{\frac{n}{2}}}{\sqrt{b + \sqrt{- 4 a c + b^{2}}}} \right )}}{n \sqrt{b + \sqrt{- 4 a c + b^{2}}} \sqrt{- 4 a c + b^{2}}} + \frac{2 \sqrt{2} \sqrt{c} \operatorname{atan}{\left (\frac{\sqrt{2} \sqrt{c} x^{\frac{n}{2}}}{\sqrt{b - \sqrt{- 4 a c + b^{2}}}} \right )}}{n \sqrt{b - \sqrt{- 4 a c + b^{2}}} \sqrt{- 4 a c + b^{2}}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate(x**(-1+1/2*n)/(a+b*x**n+c*x**(2*n)),x)

[Out]

-2*sqrt(2)*sqrt(c)*atan(sqrt(2)*sqrt(c)*x**(n/2)/sqrt(b + sqrt(-4*a*c + b**2)))/
(n*sqrt(b + sqrt(-4*a*c + b**2))*sqrt(-4*a*c + b**2)) + 2*sqrt(2)*sqrt(c)*atan(s
qrt(2)*sqrt(c)*x**(n/2)/sqrt(b - sqrt(-4*a*c + b**2)))/(n*sqrt(b - sqrt(-4*a*c +
 b**2))*sqrt(-4*a*c + b**2))

_______________________________________________________________________________________

Mathematica [C]  time = 0.0558754, size = 60, normalized size = 0.36 \[ \frac{\text{RootSum}\left [\text{$\#$1}^4 c+\text{$\#$1}^2 b+a\&,\frac{2 \log \left (x^{n/2}-\text{$\#$1}\right )-n \log (x)}{2 \text{$\#$1}^3 c+\text{$\#$1} b}\&\right ]}{2 n} \]

Antiderivative was successfully verified.

[In]  Integrate[x^(-1 + n/2)/(a + b*x^n + c*x^(2*n)),x]

[Out]

RootSum[a + b*#1^2 + c*#1^4 & , (-(n*Log[x]) + 2*Log[x^(n/2) - #1])/(b*#1 + 2*c*
#1^3) & ]/(2*n)

_______________________________________________________________________________________

Maple [C]  time = 0.179, size = 114, normalized size = 0.7 \[ \sum _{{\it \_R}={\it RootOf} \left ( \left ( 16\,{a}^{3}{c}^{2}{n}^{4}-8\,{a}^{2}{b}^{2}c{n}^{4}+a{b}^{4}{n}^{4} \right ){{\it \_Z}}^{4}+ \left ( -4\,abc{n}^{2}+{b}^{3}{n}^{2} \right ){{\it \_Z}}^{2}+c \right ) }{\it \_R}\,\ln \left ({x}^{{\frac{n}{2}}}+ \left ( 4\,{n}^{3}b{a}^{2}-{\frac{{n}^{3}{b}^{3}a}{c}} \right ){{\it \_R}}^{3}+ \left ( 2\,an-{\frac{{b}^{2}n}{c}} \right ){\it \_R} \right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int(x^(-1+1/2*n)/(a+b*x^n+c*x^(2*n)),x)

[Out]

sum(_R*ln(x^(1/2*n)+(4*n^3*b*a^2-1/c*n^3*b^3*a)*_R^3+(2*a*n-1/c*n*b^2)*_R),_R=Ro
otOf((16*a^3*c^2*n^4-8*a^2*b^2*c*n^4+a*b^4*n^4)*_Z^4+(-4*a*b*c*n^2+b^3*n^2)*_Z^2
+c))

_______________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \[ \int \frac{x^{\frac{1}{2} \, n - 1}}{c x^{2 \, n} + b x^{n} + a}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x^(1/2*n - 1)/(c*x^(2*n) + b*x^n + a),x, algorithm="maxima")

[Out]

integrate(x^(1/2*n - 1)/(c*x^(2*n) + b*x^n + a), x)

_______________________________________________________________________________________

Fricas [A]  time = 0.295488, size = 1081, normalized size = 6.4 \[ \text{result too large to display} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x^(1/2*n - 1)/(c*x^(2*n) + b*x^n + a),x, algorithm="fricas")

[Out]

1/2*sqrt(2)*sqrt(-((a*b^2 - 4*a^2*c)*n^2*sqrt(1/((a^2*b^2 - 4*a^3*c)*n^4)) + b)/
((a*b^2 - 4*a^2*c)*n^2))*log((4*c*x*x^(1/2*n - 1) + sqrt(2)*((a*b^3 - 4*a^2*b*c)
*n^3*sqrt(1/((a^2*b^2 - 4*a^3*c)*n^4)) - (b^2 - 4*a*c)*n)*sqrt(-((a*b^2 - 4*a^2*
c)*n^2*sqrt(1/((a^2*b^2 - 4*a^3*c)*n^4)) + b)/((a*b^2 - 4*a^2*c)*n^2)))/x) - 1/2
*sqrt(2)*sqrt(-((a*b^2 - 4*a^2*c)*n^2*sqrt(1/((a^2*b^2 - 4*a^3*c)*n^4)) + b)/((a
*b^2 - 4*a^2*c)*n^2))*log((4*c*x*x^(1/2*n - 1) - sqrt(2)*((a*b^3 - 4*a^2*b*c)*n^
3*sqrt(1/((a^2*b^2 - 4*a^3*c)*n^4)) - (b^2 - 4*a*c)*n)*sqrt(-((a*b^2 - 4*a^2*c)*
n^2*sqrt(1/((a^2*b^2 - 4*a^3*c)*n^4)) + b)/((a*b^2 - 4*a^2*c)*n^2)))/x) - 1/2*sq
rt(2)*sqrt(((a*b^2 - 4*a^2*c)*n^2*sqrt(1/((a^2*b^2 - 4*a^3*c)*n^4)) - b)/((a*b^2
 - 4*a^2*c)*n^2))*log((4*c*x*x^(1/2*n - 1) + sqrt(2)*((a*b^3 - 4*a^2*b*c)*n^3*sq
rt(1/((a^2*b^2 - 4*a^3*c)*n^4)) + (b^2 - 4*a*c)*n)*sqrt(((a*b^2 - 4*a^2*c)*n^2*s
qrt(1/((a^2*b^2 - 4*a^3*c)*n^4)) - b)/((a*b^2 - 4*a^2*c)*n^2)))/x) + 1/2*sqrt(2)
*sqrt(((a*b^2 - 4*a^2*c)*n^2*sqrt(1/((a^2*b^2 - 4*a^3*c)*n^4)) - b)/((a*b^2 - 4*
a^2*c)*n^2))*log((4*c*x*x^(1/2*n - 1) - sqrt(2)*((a*b^3 - 4*a^2*b*c)*n^3*sqrt(1/
((a^2*b^2 - 4*a^3*c)*n^4)) + (b^2 - 4*a*c)*n)*sqrt(((a*b^2 - 4*a^2*c)*n^2*sqrt(1
/((a^2*b^2 - 4*a^3*c)*n^4)) - b)/((a*b^2 - 4*a^2*c)*n^2)))/x)

_______________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \[ \text{Timed out} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x**(-1+1/2*n)/(a+b*x**n+c*x**(2*n)),x)

[Out]

Timed out

_______________________________________________________________________________________

GIAC/XCAS [F]  time = 0., size = 0, normalized size = 0. \[ \int \frac{x^{\frac{1}{2} \, n - 1}}{c x^{2 \, n} + b x^{n} + a}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x^(1/2*n - 1)/(c*x^(2*n) + b*x^n + a),x, algorithm="giac")

[Out]

integrate(x^(1/2*n - 1)/(c*x^(2*n) + b*x^n + a), x)